package com.forum.service.impl;

import com.baomidou.mybatisplus.mapper.Wrapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;

import com.forum.dao.DataevaluationDao;
import com.forum.entity.DataevaluationEntity;
import com.forum.entity.view.DataevaluationView;
import com.forum.service.DataevaluationService;
import com.forum.utils.MyQuery;
import com.forum.utils.PageUtils;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * <p>
 * 资料评论表 服务实现类
 * </p>
 *
 * @author LiangFeng
 * @since 2023-12-26
 */
@Service
public class DataevaluationServiceImpl extends ServiceImpl<DataevaluationDao, DataevaluationEntity> implements DataevaluationService {

    @Override
    public PageUtils queryPage(Map<String, Object> params, Wrapper<DataevaluationEntity> wrapper) {
        Page<DataevaluationView> page = new MyQuery<DataevaluationView>(params).getPage();
        page.setRecords(baseMapper.selectListView(page,wrapper));
        PageUtils pageUtils = new PageUtils(page);
        return pageUtils;
    }


}
